Conventionally, a stroke amount detection device that detects a stroke amount of a detection object is known. For example, JP-A-2011-220795 (corresponding to US 2011/0248705 A1 and referred to as a patent document No. 1 hereafter) discloses a stroke amount detection device that includes a Hall element, a yoke, and permanent magnets attached to the yoke and detects a stroke amount of a detection object based on an output signal of the Hall element. Because the stroke amount detection device disclosed in the patent document No. 1 uses a repulsion of magnets, two permanent magnets facing each other across a virtual straight line on which the detection object moves are attached to the yoke.
In the stroke amount detection device disclosed in the patent document No. 1, because the two permanent magnets are provided, the number of components is large.